package com.ccit.model;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.springframework.data.annotation.Id;
import org.springframework.data.mongodb.core.mapping.Document;

import java.sql.Timestamp;
import java.util.Date;

@Data
@AllArgsConstructor
@NoArgsConstructor
@ApiModel("课程订单")
@Document("CourseOrder")
@TableName("course_order")
public class CourseOrder {
    private static final long serialVersionUID = 1L;

    @Id
    @ApiModelProperty(value = "UUID")
    @TableId(value = "id")
    private String id;

    @ApiModelProperty(value = "课程id")
    @TableField(value = "course_id")
    private Long courseId;

    @ApiModelProperty(value = "课程")
    @TableField(exist = false)
    private Course course;

    @ApiModelProperty(value = "会员手机号")
    @TableField("member_phone")
    private String memberPhone;

    @ApiModelProperty(value = "教练名称")
    @TableField("coach")
    private String coach;

    @ApiModelProperty(value = "订单生成时间")
    @TableField("time")
    private Date time;

    @ApiModelProperty("订单价格")
    @TableField("price")
    private double price;


}
